// Bol Processor version BP2.7.1
// Data file saved as '-da.checkControls.html'. Date: Mer 11 Juin 1997 -- 8:47
-gl.D50
-se.checkControls
// This are examples of effects controlled by BP2
// All these examples are available on demo cassettes
// These have been designed for Roland D-50 equiped with a Musitronics expansion board, but they can be adapted to other synths, notably General MIDI. Patches "Shakuhachi" and "LoudPiano" have equivalents in "-gl.GeneralMIDI", but multi-timbral patch "TheBlueNoteJazz" has no equivalent and should be designed with two different timbres on channels 2 and 4.
// Csound users may check the ヤWrite Csound scoresユ and ヤTrace Csoundユ buttons (Settings window)
// #1 Transposition
// Default transposition is 0.
Shakuhachi -- do4 re4 mi4 _transpose(-5) do4 re4 mi4 {fa4 mi4 re4,si4 la4 sol4 } _transpose(0) do4 {_transpose(-5) fa4 mi4 re4,si4 la4 sol4 } {fa4 mi4 re4,si4 la4 sol4 } mi4 re4 do4
// #2 Transposition. Note that BP2 clips key numbers within the MIDI range (0..127) by shifting octaves on notes beyond that range.
LoudPiano -- do4 re4 mi4 _transpose(-128) do4 re4 mi4 {fa4 mi4 re4,si4 la4 sol4 } _transpose(0) do4
// Velocity controls
// Note that default velocity is 64.
// #3 Simple control
Shakuhachi -- _vel(40) do4 re4 mi4 fa4 _vel(120) sol4 {2,fa4 mi4 re4 mi4 re4} _vel(30) do4 re4 mi4 fa4
// #4 Stepwise variation 5 to 127, and from 127 down to 10
Shakuhachi -- _vel(5) _velstep do4 re4 mi4 fa4 _vel(127) do4 re4 mi4 fa4 _vel(10) re4 do4
// #5 Stepwise variation 5 to 127, then keep value 127, eventually change suddenly to 10
// Reduce tempo if you can't hear!
Shakuhachi -- _vel(5) _velstep do4 re4 mi4 fa4 sol4 fa4 mi4 re4 do4 re4 mi4 fa4 _vel(127) _velfixed do4 re4 mi4 fa4 sol4 fa4 mi4 _vel(20) re4 do4
// #6 Stepwise variation until "_velfixed", then constant value (82) until "_vel(127)", then stepwise down from 127 to 10. The constant value is approximately 70.
Shakuhachi -- _vel(20) _velstep do4 re4 mi4 fa4 sol4 fa4 mi4 _velfixed re4 do4 re4 mi4 fa4 _vel(127) _velstep do4 re4 mi4 fa4 sol4 fa4 mi4 _vel(10) re4 do4
// #7 Here we control several fields of a polymetric structure with the same velocity value that keeps increasing from 10 to 127.
Shakuhachi -- _vel(10) _velstep do4 re4 mi4 fa4 sol4 fa4 mi4 re4 do4 re4 mi4 fa4 {do4 mi4 re4 fa4, sol4 si4 do5} _vel(127)
// #8 Multichannel and polyphonic version. Use D-50 or create a multi-timbral patch using channels 2 and 4.
TheBlueNoteJazz -- _chan(K1=2) _vel(10) _velstep do4 re4 mi4 fa4 sol4 fa4 mi4 re4 do4 re4 mi4 fa4 _vel(127) _velfixed do4 _vel(30) mi4 re4 fa4 _chan(4) sol4 si4 do5 {_chan(K1) do4 _vel(30) mi4 re4 fa4,_vel(70) _chan(4) sol4 si4 do5} _script(MIDI all notes off channel 2)
// #9 Also multi-timbral. We keep a separate control "_vel(40)" on one voice.
TheBlueNoteJazz -- _vel(10) _velstep _chan(K1=2) do4 re4 mi4 fa4 sol4 fa4 mi4 re4 do4 re4 mi4 fa4 do4 mi4 re4 fa4 {_chan(K1) do4 mi4 re4 fa4, _chan(4) _vel(40) sol4 si4 do5} _chan(K1) fa4 mi4 re4 do4 _vel(127)
// Volume control.
// #10 Stepwise control. "_volumecontrol(7)" is not necessary because controller 7 is the default volume controller.
Shakuhachi -- _volumecontrol(7) _volume(30) _volumestep do4 re4 mi4 fa4 sol4 fa4 mi4 re4 do4 re4 mi4 fa4 _volume(127)
// #11 Continuous control.
// Note that parameters K1,K2,.. may also be controlled by external MIDI devices.
// The default value of _volumerate is 50 samples per second.
Shakuhachi -- _volumerate(40) _volumecont _volume(K1=64) re4_______ _volume(127) ________ _volume(K2=10) _____ _volume(K1)
// #12 Controlling volume on channel 4. This will work if the synth is in "OMNI ON" mode or
// its keyboard is on channel 4.
// Here we expect that the keyboard is not on channel 4, so we put the synth in OMNI mode
// This is done by the "_script()" command which is only effective if the "Internal"
// bank is selected! There are also lots of silences in the beginning to give
// time to the D-50 to set-up changes.
Internal - _script(MIDI Omni mode ON channel 1) -- TheBlueNoteJazz --- _chan(4) _volumestep _volume(30) do4 re4 mi4 fa4 sol4 fa4 mi4 re4 do4 re4 mi4 fa4 _volume(127)
// #13 Almost the same example except that "_volume(20)" is placed before "_chan(4)".
// Consequently, control is sent on channel 1 (the default channel). This will work if the synth is in "OMNI ON" mode or its keyboard is on channel 1.
Internal - _script(MIDI Omni mode ON channel 1) -- TheBlueNoteJazz --- _volumestep _volume(20) _chan(4) do4 re4 mi4 fa4 sol4 fa4 mi4 re4 do4 re4 mi4 fa4 _volume(127)
// #14 Continuous control of volume, channel 2. Same remark regarding channels.
// "_volumerate(10)" must be placed after "_chan(2)" so that the rate is fixed on the
// desired channel.
// Beware that "_volumecont" precedes the first "_volume()" instruction!
Internal - _script(MIDI Omni mode ON channel 1) -- TheBlueNoteJazz --- _chan(2) _volumerate(10) _volumecont _volume(127) do4 _ _volume(10) __ _volume(127) __ _volume(0) __ _volume(100)_______
// #15 Controlling volume on several channels. This may not work
// properly if the synth (e.g. D-50) does not recognize positions of volume pedals on
// separate channels. Either the setting is "OMNI ON" and all _volume() will change the unique
// pedal (the one with the same MIDI channel as the keyboard), or "OMNI OFF" and only
// _volume() on the same channel as the keyboard will be recognized.
TheBlueNoteJazz -- {_chan(2) _volumerate(50) _volumecont _volume(127) do4________volume(0)____ _volume(127),_chan(5) _volumefixed _volume(64) sol4 ________}
// #16 Similar example producing different results on D-50.
// With "OMNI ON" and keyboard on channel 1, volume is changed on both channels. In fact,
// the control on channel 4 replaces the one on channel 2.
// With "OMNI OFF" and keyboard on channel 2, the control on channel 4 is ignored.
// With "OMNI OFF" and keyboard on channel 4, the control on channel 2 is ignored.
// I have written _volume(64) at the end of the item because you might forget to move the
// pedal of your synth and it would remain silent, unless 'Reset controllers' is checked!
TheBlueNoteJazz -- _chan(2) _volumestep _volume(127) do4 re4 mi4 fa4 sol4 fa4 mi4 re4 do4 _chan(4) sol4 si4 do5 {_chan(2) do4 mi4 re4 fa4 do4 mi4 re4 fa4, _chan(4) _volumecont _volume(127) sol4 si4 do5 sol4 si4 do5 _volume(30)} _chan(2) _volume(0) --- _volume(64)
// There are other remarks regarding the continuous or stepwise control of parameters like
// velocity, articulation, volume, pitchbender, modulation and pressure on several
// channels in a single sequence. See the last examples of pitchbend control below and apply
// the same principles
// Pitchbend control. It is advisable to reset the pitch bender to its initial value before
// exiting. At least, BP2 resets pitchbenders on all channels before starting an item.
// Result depends on the pitchbend range of your patch, which is declared
// by _pitchrange(x). For example, if the total range is 4 semitones, i.e. +/- 200 cents,
// you should declare _pitchrange(200). BP2 only checks that the value sent via MIDI
// falls in range 0..16383, where '0' means here '-200 cents' and '16383' means '+200 cents'.
// The rate of sampling (default 50 samples per second) is declared by _pitchrate()
// #17 Pitch bender used to modify individual notes
// "_pitchrange(200)" must be placed after "_chan(1)" so that it is assigned to the proper
// channel
Cello -- _chan(1) _pitchrange(200) do4 re4 _pitchbend(0) mi4 fa4 sol4 fa4 mi4 re4 do4 re4 mi4 fa4 _pitchbend(50) mi4 fa4 sol4 fa4 mi4 re4 do4 _pitchbend(0)
// #18 A stepwise portamento: bender values are interpolated between -200 and +200 cents
Cello -- _pitchrange(200) _pitchbend(-50) _pitchstep re4 re4 re4 re4 re4 re4 _pitchbend(50) _pitchbend(0)
// #19 Also stepwise, but notes are not stroked again. Will only produce effect if the 'hold' pedal is on, which is done automatically by _switchon(64,1).
Cello -- _chan(1) _pitchrange(200) _pitchbend(-200) _switchon(64,1) _pitchbend(+200) _pitchstep re4 - - - - - - - _pitchbend(-200) _switchoff(64,1)
// #20 A simple continuous portamento
Cello -- _pitchrange(200) _pitchcont _pitchbend(+200) re4_ _ _ _ _ _ _ _pitchbend(-200)
// #21 Continuous portamento down and up
Cello -- _pitchrange(200) _pitchcont _pitchbend(+200) re4 _ _ _ _ _ _ _ _pitchbend(-200) _ _ _ _ _ _ _ _ _ _ _pitchbend(+160) _ _ _ _ _ _ _pitchbend(-200) _ _ _pitchbend(0) _ _ _ _
// #22 Same portamento, faster.
Cello -- /4 _pitchrange(200) _pitchcont _pitchbend(+200) re4 _ _ _ _ _ _ _ _pitchbend(-200) _ _ _ _ _ _ _ _ _ _ _pitchbend(+160) _ _ _ _ _ _ _pitchbend(-200) _ _ _pitchbend(0) _ _ _ _
// #23 Same portamento played twice and very fast. The limitation for obtaining accuracy is only the sampling period of the pitch bender (default 50 samples per second)
// Remember that PitchBend messages are produced in real time, not stored in memory, so that the movement may be quite complex.
Shakuhachi -- /16 _pitchrange(200) _pitchcont _pitchbend(+200) re4 _ _ _ _ _ _ _ _pitchbend(-200) _ _ _ _ _ _ _ _ _ _ _pitchbend(+160) _ _ _ _ _ _ _pitchbend(-200) _ _ _pitchbend(0) _ _ _ _pitchbend(+200) _ _ _ _ _ _ _ _pitchbend(-200) _ _ _ _ _ _ _ _ _ _ _pitchbend(+160) _ _ _ _ _ _ _pitchbend(-200) _ _ _pitchbend(0) _ _ _
// #24 Portamento on multichannel item
// Unlike volume control, pitch control is properly separated on each channel in most
// synth's.
// Note that the first field of the polymetric volume ("do4") is assigned channel 5
// because it was the channel before entering the polymetric structure.
// It is useful to specify _chan(5) at the very beginning of the item because the pitchbender
// is reset on the first sound-object (here, a silence); that sound-object should be on
// channel 5.
TheBlueNoteJazz -- _chan(5) _pitchrange(200) - - do4___ { _vel(10) _pitchbend(-200) _pitchcont do4______________ _pitchbend(+200),_chan(2) _vel(127) _volume(127) sol4______________}
// #25 Here no portamento is produced on sol4 because it is on channel 2. But the
// pitchbend continues going down on channel 5.
TheBlueNoteJazz -- _chan(5) _pitchrange(200) _pitchbend(+200) _pitchcont do4____ do4_____ _chan(2) sol4____________ _chan(5) do4______ do4______ _pitchbend(-200)
// #26 Similar case in polyphonic piece.
TheBlueNoteJazz -- _chan(5) _pitchrange(200) _pitchbend(-200) _pitchcont do4___ { _vel(10) _volume(40) do4______________,_chan(2) _vel(127) _volume(127) sol4______________} do4___ _pitchbend(+200)
// #27 Using object concatenation '&' to extend durations
TheBlueNoteJazz -- _chan(5) _pitchrange(200) _pitchbend(-200) _pitchcont do4___& {&do4______________&,_chan(2) _vel(127) _volume(127) sol4______________} &do4___ _pitchbend(+200)
// #28 Controlling pitchbenders on two separate channels. You can use up to 16 channels with separate simultaneous movements.
// "_pitchrange()" must be placed after each "_chan()" so that it is assigned to the proper channel.
TheBlueNoteJazz -- _volume(70) {_chan(5) _pitchrange(200) _pitchbend(+200) _pitchcont do4________pitchbend(-200)_________ _pitchbend(0),_chan(2) _vel(127) _pitchrange(200) _pitchbend(-200) _pitchcont sol4 _______________pitchbend(+200)}
// #29 Here is an example that will not work: attempting to control pitch on two separate channels on overlapping time intervals in the same sequence. The portamento on channel 5 will resume at (150) after 'sol4' instead of continuing the initial line.
TheBlueNoteJazz -- _volume(80) _chan(5) _pitchrange(200) _pitchbend(+200) _pitchcont do4_____ _chan(2) _pitchrange(200) _pitchcont _pitchbend(-150) sol4__ _pitchbend(150) _chan(5) do4______ do4______ _pitchbend(-200)
// #30 This is a proper way of writing the previous example.
TheBlueNoteJazz -- _volume(80) _chan(5) _pitchrange(200) _pitchbend(+200) _pitchcont do4_____ {---,_chan(2) _pitchrange(200) _pitchcont _pitchbend(-150) sol4__ _pitchbend(150)} do4______ do4______ _pitchbend(-200)
// #31 Here is a shorter representation yielding exactly the same result.
TheBlueNoteJazz -- _volume(80) _chan(5) _pitchrange(200) _pitchbend(+200) _pitchcont do4_____ {_chan(2) _pitchrange(200) _pitchcont _pitchbend(-150) sol4__ _pitchbend(150)} do4______ do4______ _pitchbend(-200)
// Modulation
// #32 Step changes of modulation
// It is useful to reset modulation to 0 at the end.
Shakuhachi -- _modstep _mod(0) re4_____ re4_____ re4_____ re4_____ re4_____ _mod(16383) _mod(0)
// #33 Continuous change of modulation
// The rate of sampling (default 50 samples per second) is declared by _modrate()
// Be careful to write "_modcont" before the first "_mod()" instruction.
Shakuhachi -- _modrate(30) _modcont _mod(0) re4 ________________ _mod(16383) mi4______________________ _mod(0)_________
// #34 Changing both pitch and modulation
Violin -- _pitchrange(200) _modcont _pitchcont _mod(16383) _pitchbend(+200) re4_____ _vel(100) _pitchbend(-200) ________________ _pitchbend(0) _mod(0)
// Channel pressure
// #35 Changing channel pressure by steps
// Note: on this patch of D-50 channel pressure produces the same effect as modulation
// It may be useful to reset to 0 at the end, unless "Reset controllers" is checked.
Violin -- _chan(1) _presstep _press(5) do4 _ _ _ do4 _ _ _ do4 _ _ _ do4 _ _ _ _ _ _ _ _press(127) _press(0)
// #36 Changing channel pressure continuously
// The rate of sampling (default 50 samples per second) is declared by _pressrate()
Violin -- _pressrate(30) _presscont _press(0) do4 ___ do4 ___ do4 ___ do4 _______ _press(127) _press(0)
// #37 Here the initial value (0) is stored in K1
Violin -- _chan(1) _presscont _press(K1=0) do4 _________________ _press(127) ____________ _press(K1) ____
// #38 Changing pitch and channel pressure independently
Violin -- _pressrate(30) _pitchrate(40) _pitchrange(200) _press(0) _pitchbend(0) _pitchcont _presscont do4 ____________ _pitchbend(+200) _____ _press(127) ___ _pitchbend(-200) _________ _press(0) ____ _pitchbend(0)
// #39 Panoramic control
// Works only if a MIDI controller is assigned to panoramic control, as per General MIDI specs, by default controller 10.
// I haven't been able to check this on D-50, so please report if successful
// and tell me whether "left" is 0 or 127.
// Here, "_pancontrol(10)" is not needed because it's the default value.
Shakuhachi -- _pancontrol(10) _panrate(40) _pancont _pan(0) re4_______ _pan(127) ________ _pan(K2=10) _____ _pan(80) _________ _pan(K2)
// Of course, you can combine all the effects described above: controlling velocity, volume, articulation, pitch, modulation, pressure, in polyphonic and multichannel items. The limitation is only the MIDI system: you can't, for instance, assign different PitchBend values to simultaneous notes on the same MIDI channel.
// #40 Controlling switches 64 to 95 (64 is the 'hold' pedal)
Violin -- do4 --- do4 --- _switchon(64,1) do4 --- do4 _switchoff(64,1) --- do4
//--------------------------------------------------------+